1. Field of the Invention
The present invention relates to a host peripheral system and method, and more particularly, to a host peripheral system and method for loading an external program code to a host for setting up a transmission mechanism when booting.
2. Description of the Prior Art
Please refer to FIG. 1, which is a functional block diagram schematically illustrating the system of a prior-art host 100. The host 100 comprises a central processing unit (CPU) 110, a read only memory (ROM) 120, a main memory 115, a hard disc drive 130, a main board 140, an optical disc drive 145, a sound effect card 150, a floppy disc drive 155, a keyboard 160, a display card 165, a mouse 170, and a host serial interface port 175. The CPU 110 functions to manage process control and perform system kernel operations of the host 100. The ROM 120 stores the initial program code of the basic input/output system (BIOS) 125 for setting the system configuration of the host 100 while booting. The main memory 115 stores the buffer data ready for processing. The CPU 110, the ROM 120, the main memory 115, the display card 165, the sound effect card 150 and the host serial interface port 175 are installed on the main board 140. The hard disc drive 130, the optical disc drive 145, the floppy disc drive 155, the keyboard 160 and the mouse 170 are coupled to the main board 140. The host serial interface port 175 may be utilized to couple an external host peripheral device for providing a data transmission interface between the host 100 and the external host peripheral device. The host serial interface port 175 can be a universal serial bus (USB) interface port, a serial advanced technology attachment (SATA) interface port, or a serial attached small computer system interface (Serial Attached SCSI, SAS) port.
The hard disc drive 130 stores an operating system 135. When the host 100 is powered, the host 100 executes the initial program code of the basic input/output system 125 for performing initialization processes such as the power-on self test (POST), the plug and play test, and various hardware configuration settings. After finishing the aforementioned initialization processes, the host 100 loads the operating system 135 so that functional operations can be performed through associating the hardware and software of the host 100 based on the configuration settings. The functional operations of the host 100 comprise memory accessing control, CPU processing control, file system managing control, and input/output control, etc.
Please refer to FIG. 2, which presents a flowchart depicting the booting operation of the host 100 shown in FIG. 1. The booting operation of the host 100 comprises the following steps:
Step S205: Power the host 100;
Step S210: Load the initial program code of the basic input/output system 125 stored in the ROM 120 into the main memory 115;
Step S215: Perform the process of power-on self test;
Step S220: Detect all the bootable devices attached to the host 100;
Step S225: Select a bootable device as the boot device and load the boot code stored in the boot sector of the selected bootable device into the host 100 for controlling the following booting processes;
Step S230: Load and execute the operating system 135 based on the boot code; and
Step S235: Perform functional operations of memory accessing control, CPU processing control, file system managing control, and input/output control, etc., based on the operating system 135.
In summary, the prior-art booting operation is carried out by loading the operating system based on the boot code of a bootable device immediately after performing the process of power-on self test for enabling the host to perform related functional operations.